From 64bf92684260c314a9fa3f5f794fa05346fd022d Mon Sep 17 00:00:00 2001 From: Jimi Xenidis Date: Thu, 27 Jul 2006 18:57:34 -0400 Subject: [PATCH] [powerpc] Use new method to detect NULL xencomm handle old method wasted cycles and could give false positive. Signed-off-by: Jimi Xenidis --- xen/arch/powerpc/usercopy.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/xen/arch/powerpc/usercopy.c b/xen/arch/powerpc/usercopy.c index 77ec80c66c..b555586007 100644 --- a/xen/arch/powerpc/usercopy.c +++ b/xen/arch/powerpc/usercopy.c @@ -238,5 +238,5 @@ int xencomm_handle_is_null(void *ptr) desc = (struct xencomm_desc *)paddr_to_maddr((unsigned long)ptr); - return (desc->address[0] == XENCOMM_INVALID); + return (desc->nr_addrs == 0); } -- 2.30.2